<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
  "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">


<html xmlns="http://www.w3.org/1999/xhtml">
  <head>
    <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
    
    <title>Django 1.7.2 release notes &mdash; Django 1.7.8.dev20150401230226 documentation</title>
    
    <link rel="stylesheet" href="../_static/default.css" type="text/css" />
    <link rel="stylesheet" href="../_static/pygments.css" type="text/css" />
    
    <script type="text/javascript">
      var DOCUMENTATION_OPTIONS = {
        URL_ROOT:    '../',
        VERSION:     '1.7.8.dev20150401230226',
        COLLAPSE_INDEX: false,
        FILE_SUFFIX: '.html',
        HAS_SOURCE:  true
      };
    </script>
    <script type="text/javascript" src="../_static/jquery.js"></script>
    <script type="text/javascript" src="../_static/underscore.js"></script>
    <script type="text/javascript" src="../_static/doctools.js"></script>
    <link rel="top" title="Django 1.7.8.dev20150401230226 documentation" href="../index.html" />
    <link rel="up" title="Release notes" href="index.html" />
    <link rel="next" title="Django 1.7.1 release notes" href="1.7.1.html" />
    <link rel="prev" title="Django 1.7.3 release notes" href="1.7.3.html" />



 
<script type="text/javascript" src="../templatebuiltins.js"></script>
<script type="text/javascript">
(function($) {
    if (!django_template_builtins) {
       // templatebuiltins.js missing, do nothing.
       return;
    }
    $(document).ready(function() {
        // Hyperlink Django template tags and filters
        var base = "../ref/templates/builtins.html";
        if (base == "#") {
            // Special case for builtins.html itself
            base = "";
        }
        // Tags are keywords, class '.k'
        $("div.highlight\\-html\\+django span.k").each(function(i, elem) {
             var tagname = $(elem).text();
             if ($.inArray(tagname, django_template_builtins.ttags) != -1) {
                 var fragment = tagname.replace(/_/, '-');
                 $(elem).html("<a href='" + base + "#" + fragment + "'>" + tagname + "</a>");
             }
        });
        // Filters are functions, class '.nf'
        $("div.highlight\\-html\\+django span.nf").each(function(i, elem) {
             var filtername = $(elem).text();
             if ($.inArray(filtername, django_template_builtins.tfilters) != -1) {
                 var fragment = filtername.replace(/_/, '-');
                 $(elem).html("<a href='" + base + "#" + fragment + "'>" + filtername + "</a>");
             }
        });
    });
})(jQuery);
</script>


  </head>
  <body>

    <div class="document">
  <div id="custom-doc" class="yui-t6">
    <div id="hd">
      <h1><a href="../index.html">Django 1.7.8.dev20150401230226 documentation</a></h1>
      <div id="global-nav">
        <a title="Home page" href="../index.html">Home</a>  |
        <a title="Table of contents" href="../contents.html">Table of contents</a>  |
        <a title="Global index" href="../genindex.html">Index</a>  |
        <a title="Module index" href="../py-modindex.html">Modules</a>
      </div>
      <div class="nav">
    &laquo; <a href="1.7.3.html" title="Django 1.7.3 release notes">previous</a>
     |
    <a href="index.html" title="Release notes" accesskey="U">up</a>
   |
    <a href="1.7.1.html" title="Django 1.7.1 release notes">next</a> &raquo;</div>
    </div>

    <div id="bd">
      <div id="yui-main">
        <div class="yui-b">
          <div class="yui-g" id="releases-1.7.2">
            
  <div class="section" id="s-django-1-7-2-release-notes">
<span id="django-1-7-2-release-notes"></span><h1>Django 1.7.2 release notes<a class="headerlink" href="#django-1-7-2-release-notes" title="Permalink to this headline">¶</a></h1>
<p><em>January 2, 2015</em></p>
<p>Django 1.7.2 fixes several bugs in 1.7.1.</p>
<p>Additionally, Django&#8217;s vendored version of six, <a class="reference internal" href="../topics/python3.html#module-django.utils.six" title="django.utils.six"><tt class="xref py py-mod docutils literal"><span class="pre">django.utils.six</span></tt></a>, has
been upgraded to the latest release (1.9.0).</p>
<div class="section" id="s-bugfixes">
<span id="bugfixes"></span><h2>Bugfixes<a class="headerlink" href="#bugfixes" title="Permalink to this headline">¶</a></h2>
<ul class="simple">
<li>Fixed migration&#8217;s renaming of auto-created many-to-many tables when changing
<a class="reference internal" href="../ref/models/options.html#django.db.models.Options.db_table" title="django.db.models.Options.db_table"><tt class="xref py py-attr docutils literal"><span class="pre">Meta.db_table</span></tt></a> (<a class="reference external" href="https://code.djangoproject.com/ticket/23630">#23630</a>).</li>
<li>Fixed a migration crash when adding an explicit <tt class="docutils literal"><span class="pre">id</span></tt> field to a model on
SQLite (<a class="reference external" href="https://code.djangoproject.com/ticket/23702">#23702</a>).</li>
<li>Added a warning for duplicate models when a module is reloaded. Previously a
<tt class="docutils literal"><span class="pre">RuntimeError</span></tt> was raised every time two models clashed in the app registry.
(<a class="reference external" href="https://code.djangoproject.com/ticket/23621">#23621</a>).</li>
<li>Prevented <a class="reference internal" href="../ref/django-admin.html#django-admin-flush"><tt class="xref std std-djadmin docutils literal"><span class="pre">flush</span></tt></a> from loading initial data for migrated apps
(<a class="reference external" href="https://code.djangoproject.com/ticket/23699">#23699</a>).</li>
<li>Fixed a <a class="reference internal" href="../ref/django-admin.html#django-admin-makemessages"><tt class="xref std std-djadmin docutils literal"><span class="pre">makemessages</span></tt></a> regression in 1.7.1 when
<a class="reference internal" href="../ref/settings.html#std:setting-STATIC_ROOT"><tt class="xref std std-setting docutils literal"><span class="pre">STATIC_ROOT</span></tt></a> has the default <tt class="docutils literal"><span class="pre">None</span></tt> value (<a class="reference external" href="https://code.djangoproject.com/ticket/23717">#23717</a>).</li>
<li>Added GeoDjango compatibility with mysqlclient database driver.</li>
<li>Fixed MySQL 5.6+ crash with <tt class="docutils literal"><span class="pre">GeometryField</span></tt>s in migrations
(<a class="reference external" href="https://code.djangoproject.com/ticket/23719">#23719</a>).</li>
<li>Fixed a migration crash when removing a field that is referenced in
<tt class="docutils literal"><span class="pre">AlterIndexTogether</span></tt> or <tt class="docutils literal"><span class="pre">AlterUniqueTogether</span></tt> (<a class="reference external" href="https://code.djangoproject.com/ticket/23614">#23614</a>).</li>
<li>Updated the first day of the week in the Ukrainian locale to Monday.</li>
<li>Added support for transactional spatial metadata initialization on
SpatiaLite 4.1+ (<a class="reference external" href="https://code.djangoproject.com/ticket/23152">#23152</a>).</li>
<li>Fixed a migration crash that prevented changing a nullable field with a
default to non-nullable with the same default (<a class="reference external" href="https://code.djangoproject.com/ticket/23738">#23738</a>).</li>
<li>Fixed a migration crash when adding <tt class="docutils literal"><span class="pre">GeometryField</span></tt>s with <tt class="docutils literal"><span class="pre">blank=True</span></tt>
on PostGIS (<a class="reference external" href="https://code.djangoproject.com/ticket/23731">#23731</a>).</li>
<li>Allowed usage of <tt class="docutils literal"><span class="pre">DateTimeField()</span></tt> as <tt class="docutils literal"><span class="pre">Transform.output_field</span></tt>
(<a class="reference external" href="https://code.djangoproject.com/ticket/23420">#23420</a>).</li>
<li>Fixed a migration serializing bug involving <tt class="docutils literal"><span class="pre">float(&quot;nan&quot;)</span></tt> and
<tt class="docutils literal"><span class="pre">float(&quot;inf&quot;)</span></tt> (<a class="reference external" href="https://code.djangoproject.com/ticket/23770">#23770</a>).</li>
<li>Fixed a regression where custom form fields having a <tt class="docutils literal"><span class="pre">queryset</span></tt> attribute
but no <tt class="docutils literal"><span class="pre">limit_choices_to</span></tt> could not be used in a
<a class="reference internal" href="../topics/forms/modelforms.html#django.forms.ModelForm" title="django.forms.ModelForm"><tt class="xref py py-class docutils literal"><span class="pre">ModelForm</span></tt></a> (<a class="reference external" href="https://code.djangoproject.com/ticket/23795">#23795</a>).</li>
<li>Fixed a custom field type validation error with MySQL backend when
<tt class="docutils literal"><span class="pre">db_type</span></tt> returned <tt class="docutils literal"><span class="pre">None</span></tt> (<a class="reference external" href="https://code.djangoproject.com/ticket/23761">#23761</a>).</li>
<li>Fixed a migration crash when a field is renamed that is part of an
<tt class="docutils literal"><span class="pre">index_together</span></tt> (<a class="reference external" href="https://code.djangoproject.com/ticket/23859">#23859</a>).</li>
<li>Fixed <a class="reference internal" href="../ref/django-admin.html#django-admin-squashmigrations"><tt class="xref std std-djadmin docutils literal"><span class="pre">squashmigrations</span></tt></a> to respect the <tt class="docutils literal"><span class="pre">--no-optimize</span></tt> parameter
(<a class="reference external" href="https://code.djangoproject.com/ticket/23799">#23799</a>).</li>
<li>Made <a class="reference internal" href="../ref/migration-operations.html#django.db.migrations.operations.RenameModel" title="django.db.migrations.operations.RenameModel"><tt class="xref py py-class docutils literal"><span class="pre">RenameModel</span></tt></a> reversible
(<a class="reference external" href="https://code.djangoproject.com/ticket/22248">#22248</a>)</li>
<li>Avoided unnecessary rollbacks of migrations from other apps when migrating
backwards (<a class="reference external" href="https://code.djangoproject.com/ticket/23410">#23410</a>).</li>
<li>Fixed a rare query error when using deeply nested subqueries
(<a class="reference external" href="https://code.djangoproject.com/ticket/23605">#23605</a>).</li>
<li>Fixed a crash in migrations when deleting a field that is part of a
<tt class="docutils literal"><span class="pre">index/unique_together</span></tt> constraint (<a class="reference external" href="https://code.djangoproject.com/ticket/23794">#23794</a>).</li>
<li>Fixed <tt class="docutils literal"><span class="pre">django.core.files.File.__repr__()</span></tt> when the file&#8217;s <tt class="docutils literal"><span class="pre">name</span></tt> contains
Unicode characters (<a class="reference external" href="https://code.djangoproject.com/ticket/23888">#23888</a>).</li>
<li>Added missing context to the admin&#8217;s <tt class="docutils literal"><span class="pre">delete_selected</span></tt> view that prevented
custom site header, etc. from appearing (<a class="reference external" href="https://code.djangoproject.com/ticket/23898">#23898</a>).</li>
<li>Fixed a regression with dynamically generated inlines and allowed field
references in the admin (<a class="reference external" href="https://code.djangoproject.com/ticket/23754">#23754</a>).</li>
<li>Fixed an infinite loop bug for certain cyclic migration dependencies, and made
the error message for cyclic dependencies much more helpful.</li>
<li>Added missing <tt class="docutils literal"><span class="pre">index_together</span></tt> handling for SQLite (<a class="reference external" href="https://code.djangoproject.com/ticket/23880">#23880</a>).</li>
<li>Fixed a crash when <tt class="docutils literal"><span class="pre">RunSQL</span></tt> SQL content was collected by the schema editor,
typically when using <tt class="docutils literal"><span class="pre">sqlmigrate</span></tt> (<a class="reference external" href="https://code.djangoproject.com/ticket/23909">#23909</a>).</li>
<li>Fixed a regression in <tt class="docutils literal"><span class="pre">contrib.admin</span></tt> add/change views which caused some
<tt class="docutils literal"><span class="pre">ModelAdmin</span></tt> methods to receive the incorrect <tt class="docutils literal"><span class="pre">obj</span></tt> value
(<a class="reference external" href="https://code.djangoproject.com/ticket/23934">#23934</a>).</li>
<li>Fixed <tt class="docutils literal"><span class="pre">runserver</span></tt> crash when socket error message contained Unicode
characters (<a class="reference external" href="https://code.djangoproject.com/ticket/23946">#23946</a>).</li>
<li>Fixed serialization of <tt class="docutils literal"><span class="pre">type</span></tt> when adding a <tt class="docutils literal"><span class="pre">deconstruct()</span></tt> method
(<a class="reference external" href="https://code.djangoproject.com/ticket/23950">#23950</a>).</li>
<li>Prevented the
<a class="reference internal" href="../ref/middleware.html#django.contrib.auth.middleware.SessionAuthenticationMiddleware" title="django.contrib.auth.middleware.SessionAuthenticationMiddleware"><tt class="xref py py-class docutils literal"><span class="pre">SessionAuthenticationMiddleware</span></tt></a> from
setting a <tt class="docutils literal"><span class="pre">&quot;Vary:</span> <span class="pre">Cookie&quot;</span></tt> header on all responses (<a class="reference external" href="https://code.djangoproject.com/ticket/23939">#23939</a>).</li>
<li>Fixed a crash when adding <tt class="docutils literal"><span class="pre">blank=True</span></tt> to <tt class="docutils literal"><span class="pre">TextField()</span></tt> on MySQL
(<a class="reference external" href="https://code.djangoproject.com/ticket/23920">#23920</a>).</li>
<li>Fixed index creation by the migration infrastructure, particularly when
dealing with PostgreSQL specific <tt class="docutils literal"><span class="pre">{text|varchar}_pattern_ops</span></tt> indexes
(<a class="reference external" href="https://code.djangoproject.com/ticket/23954">#23954</a>).</li>
<li>Fixed bug in <tt class="docutils literal"><span class="pre">makemigrations</span></tt> that created broken migration files when
dealing with multiple table inheritance and inheriting from more than one
model (<a class="reference external" href="https://code.djangoproject.com/ticket/23956">#23956</a>).</li>
<li>Fixed a crash when a <tt class="docutils literal"><span class="pre">MultiValueField</span></tt> has invalid data (<a class="reference external" href="https://code.djangoproject.com/ticket/23674">#23674</a>).</li>
<li>Fixed a crash in the admin when using &#8220;Save as new&#8221; and also deleting a
related inline (<a class="reference external" href="https://code.djangoproject.com/ticket/23857">#23857</a>).</li>
<li>Always converted <tt class="docutils literal"><span class="pre">related_name</span></tt> to text (unicode), since that is required
on Python 3 for interpolation. Removed conversion of <tt class="docutils literal"><span class="pre">related_name</span></tt> to text
in migration deconstruction (<a class="reference external" href="https://code.djangoproject.com/ticket/23455">#23455</a> and <a class="reference external" href="https://code.djangoproject.com/ticket/23982">#23982</a>).</li>
<li>Enlarged the sizes of tablespaces which are created by default for testing
on Oracle (the main tablespace was increased from 200M to 300M and the
temporary tablespace from 100M to 150M). This was required to accommodate
growth in Django&#8217;s own test suite (<a class="reference external" href="https://code.djangoproject.com/ticket/23969">#23969</a>).</li>
<li>Fixed <tt class="docutils literal"><span class="pre">timesince</span></tt> filter translations in Korean (<a class="reference external" href="https://code.djangoproject.com/ticket/23989">#23989</a>).</li>
<li>Fixed the SQLite <tt class="docutils literal"><span class="pre">SchemaEditor</span></tt> to properly add defaults in the absence of
a user specified <tt class="docutils literal"><span class="pre">default</span></tt>. For example, a <tt class="docutils literal"><span class="pre">CharField</span></tt> with <tt class="docutils literal"><span class="pre">blank=True</span></tt>
didn&#8217;t set existing rows to an empty string which resulted in a crash when
adding the <tt class="docutils literal"><span class="pre">NOT</span> <span class="pre">NULL</span></tt> constraint (<a class="reference external" href="https://code.djangoproject.com/ticket/23987">#23987</a>).</li>
<li><tt class="docutils literal"><span class="pre">makemigrations</span></tt> no longer prompts for a default value when adding
<tt class="docutils literal"><span class="pre">TextField()</span></tt> or <tt class="docutils literal"><span class="pre">CharField()</span></tt> without a <tt class="docutils literal"><span class="pre">default</span></tt> (<a class="reference external" href="https://code.djangoproject.com/ticket/23405">#23405</a>).</li>
<li>Fixed a migration crash when adding <tt class="docutils literal"><span class="pre">order_with_respect_to</span></tt> to a table
with existing rows (<a class="reference external" href="https://code.djangoproject.com/ticket/23983">#23983</a>).</li>
<li>Restored the <tt class="docutils literal"><span class="pre">pre_migrate</span></tt> signal if all apps have migrations
(<a class="reference external" href="https://code.djangoproject.com/ticket/23975">#23975</a>).</li>
<li>Made admin system checks run for custom <tt class="docutils literal"><span class="pre">AdminSite</span></tt>s (<a class="reference external" href="https://code.djangoproject.com/ticket/23497">#23497</a>).</li>
<li>Ensured the app registry is fully populated when unpickling models. When an
external script (like a queueing infrastructure) reloads pickled models, it
could crash with an <tt class="docutils literal"><span class="pre">AppRegistryNotReady</span></tt> exception (<a class="reference external" href="https://code.djangoproject.com/ticket/24007">#24007</a>).</li>
<li>Added quoting to field indexes in the SQL generated by migrations to prevent
a crash when the index name requires it (<a class="reference external" href="https://code.djangoproject.com/ticket/24015">##24015</a>).</li>
<li>Added <tt class="docutils literal"><span class="pre">datetime.time</span></tt> support to migrations questioner (<a class="reference external" href="https://code.djangoproject.com/ticket/23998">#23998</a>).</li>
<li>Fixed admindocs crash on apps installed as eggs (<a class="reference external" href="https://code.djangoproject.com/ticket/23525">#23525</a>).</li>
<li>Changed migrations autodetector to generate an <tt class="docutils literal"><span class="pre">AlterModelOptions</span></tt> operation
instead of <tt class="docutils literal"><span class="pre">DeleteModel</span></tt> and <tt class="docutils literal"><span class="pre">CreateModel</span></tt> operations when changing
<tt class="docutils literal"><span class="pre">Meta.managed</span></tt>. This prevents data loss when changing <tt class="docutils literal"><span class="pre">managed</span></tt> from
<tt class="docutils literal"><span class="pre">False</span></tt> to <tt class="docutils literal"><span class="pre">True</span></tt> and vice versa (<a class="reference external" href="https://code.djangoproject.com/ticket/24037">#24037</a>).</li>
<li>Enabled the <tt class="docutils literal"><span class="pre">sqlsequencereset</span></tt> command on apps with migrations
(<a class="reference external" href="https://code.djangoproject.com/ticket/24054">#24054</a>).</li>
<li>Added tablespace SQL to apps with migrations (<a class="reference external" href="https://code.djangoproject.com/ticket/24051">#24051</a>).</li>
<li>Corrected <tt class="docutils literal"><span class="pre">contrib.sites</span></tt> default site creation in a multiple database
setup (<a class="reference external" href="https://code.djangoproject.com/ticket/24000">#24000</a>).</li>
<li>Restored support for objects that aren&#8217;t <a class="reference external" href="http://docs.python.org/3/library/stdtypes.html#str" title="(in Python v3.4)"><tt class="xref py py-class docutils literal"><span class="pre">str</span></tt></a> or <a class="reference external" href="http://docs.python.org/3/library/functions.html#bytes" title="(in Python v3.4)"><tt class="xref py py-class docutils literal"><span class="pre">bytes</span></tt></a> in
<a class="reference internal" href="../ref/utils.html#django.utils.safestring.mark_for_escaping" title="django.utils.safestring.mark_for_escaping"><tt class="xref py py-func docutils literal"><span class="pre">mark_for_escaping()</span></tt></a> on Python 3.</li>
<li>Supported strings escaped by third-party libraries with the <tt class="docutils literal"><span class="pre">__html__</span></tt>
convention in the template engine (<a class="reference external" href="https://code.djangoproject.com/ticket/23831">#23831</a>).</li>
<li>Prevented extraneous <tt class="docutils literal"><span class="pre">DROP</span> <span class="pre">DEFAULT</span></tt> SQL in migrations (<a class="reference external" href="https://code.djangoproject.com/ticket/23581">#23581</a>).</li>
<li>Restored the ability to use more than five levels of subqueries
(<a class="reference external" href="https://code.djangoproject.com/ticket/23758">#23758</a>).</li>
<li>Fixed crash when <tt class="docutils literal"><span class="pre">ValidationError</span></tt> is initialized with a <tt class="docutils literal"><span class="pre">ValidationError</span></tt>
that is initialized with a dictionary (<a class="reference external" href="https://code.djangoproject.com/ticket/24008">#24008</a>).</li>
<li>Prevented a crash on apps without migrations when running <tt class="docutils literal"><span class="pre">migrate</span> <span class="pre">--list</span></tt>
(<a class="reference external" href="https://code.djangoproject.com/ticket/23366">#23366</a>).</li>
</ul>
</div>
</div>


          </div>
        </div>
      </div>
      
        
          <div class="yui-b" id="sidebar">
            
      <div class="sphinxsidebar">
        <div class="sphinxsidebarwrapper">
  <h3><a href="../contents.html">Table Of Contents</a></h3>
  <ul>
<li><a class="reference internal" href="#">Django 1.7.2 release notes</a><ul>
<li><a class="reference internal" href="#bugfixes">Bugfixes</a></li>
</ul>
</li>
</ul>

  <h3>Browse</h3>
  <ul>
    
      <li>Prev: <a href="1.7.3.html">Django 1.7.3 release notes</a></li>
    
    
      <li>Next: <a href="1.7.1.html">Django 1.7.1 release notes</a></li>
    
  </ul>
  <h3>You are here:</h3>
  <ul>
      <li>
        <a href="../index.html">Django 1.7.8.dev20150401230226 documentation</a>
        
          <ul><li><a href="index.html">Release notes</a>
        
        <ul><li>Django 1.7.2 release notes</li></ul>
        </li></ul>
      </li>
  </ul>

  <h3>This Page</h3>
  <ul class="this-page-menu">
    <li><a href="../_sources/releases/1.7.2.txt"
           rel="nofollow">Show Source</a></li>
  </ul>
<div id="searchbox" style="display: none">
  <h3>Quick search</h3>
    <form class="search" action="../search.html" method="get">
      <input type="text" name="q" />
      <input type="submit" value="Go" />
      <input type="hidden" name="check_keywords" value="yes" />
      <input type="hidden" name="area" value="default" />
    </form>
    <p class="searchtip" style="font-size: 90%">
    Enter search terms or a module, class or function name.
    </p>
</div>
<script type="text/javascript">$('#searchbox').show(0);</script>
        </div>
      </div>
              <h3>Last update:</h3>
              <p class="topless">Apr 02, 2015</p>
          </div>
        
      
    </div>

    <div id="ft">
      <div class="nav">
    &laquo; <a href="1.7.3.html" title="Django 1.7.3 release notes">previous</a>
     |
    <a href="index.html" title="Release notes" accesskey="U">up</a>
   |
    <a href="1.7.1.html" title="Django 1.7.1 release notes">next</a> &raquo;</div>
    </div>
  </div>

      <div class="clearer"></div>
    </div>
  </body>
</html>